= Building Classic Phantasy Star Games on Linux

This script makes it (super?!?) easy to build the
assebly of https://en.wikipedia.org/wiki/Phantasy_Star[Phantasy Star
games] for http://segaretro.org/Sega_Mega_Drive[Mega Drive / Genesis].
The script is also able to create binary diffs (patches) too.
http://www.daemonology.net/bsdiff/[BSDiff] and http://xdelta.org/[Xdelta] for example.
So the goal is to be easy in terms of "run-one-command-and-be-done-with-it".
The project is very young at the moment. It may eventually cover more games.

The most recent (standalone) version can be found from
https://github.com/Zuccace/mdps-asm-builder

*Patches and issues should be targeted to the project above.*

== Features
 * Can create ROM binary images from assembly source files
 * Can create binary diffs (patches) between two binaries 
 * Can create checksums from the created binary ROM image

== Dependencies
It should be pretty easy once you have all the dependencies installed in your $PATH.

 * asl from http://john.ccac.rwth-aachen.de:8000/as/ - dev-lang/asl
on Gentoo https://gitlab.com/roslin-uberlay/roslin[roslin overlay]
 * gcc or clang - for automatic compiling of p2bin
 * gawk >= 4.1.1 - for assembly code "live" patching 
 * Assembly sources of said games: https://github.com/lory90/ps2disasm[II] (most actively tested),
https://github.com/lory90/ps3disasm[III] (tested once, works), and
https://github.com/lory90/ps4disasm[IV] (tested once, works)

== Usage

Just make sure build.sh has executable bit, then you can run it.
`some/path/to/build.sh <file.asm> <out.bin>`

To learn more pass the `--help` -switch alone.
Or alternatively see the source. ;)

You can create more different files just by specifying them on command line:
`some/path/to/build.sh my.asm my.xdelta my.sha256`
Note that it's *not* neccessary to specify the binary (ROM) on the line.

You can place the script wherever you want.
It should work from anywhere in the filesystem.

== Known limitations
 * Won't magically re-compress parts that need
http://segaretro.org/Kosinski_compression[Kosinski compression].
It is totally unknown at the moment if the feature will ever
be implemented into this project.

== Also...
 * This build script might work with some other disassemblies too.
It's written that in mind, but *not* tested yet.
Only Phantasy Star games are being tested.


=== TODO / Milestones
 * ??? (Suggest more features by https://github.com/Zuccace/mdps-asm-builder/issues/new[creating an issue]).
 * Clean up the code and publish first release.
